package infaraway.Factory.Factory.Creator;

import infaraway.Factory.Factory.Product.Pizza;
import infaraway.Factory.Factory.Product.Pizza1;
import infaraway.Factory.Factory.Product.Pizza2;

/**
 * Created by :Infaraway
 * DATE : 2017/4/27
 * Time : 13:38
 * Funtion :
 */
public class PizzaStore2 extends PizzaStore {
    @Override
    protected Pizza createPizza(String pizzaType) {
        switch (pizzaType) {
            case "pizza1":
                return new Pizza1();
            case "pizza2":
                return new Pizza2();
            default:
                System.out.println("no this type");
                return null;
        }
    }
}
